//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//

package com.neurosky.thinkgear;

import com.neurosky.thinkgear.TF_TD_Libraries;
import com.neurosky.thinkgear.TF_TD_Libraries.FeatureExtrationReturn;
import com.neurosky.thinkgear.TF_TD_Libraries.TF_TD_FEATUREEXTRACTION;
import com.neurosky.thinkgear.TF_TD_Libraries.TF_TD_PREPROCESSING;

public class TaskFamiliarity {
    public TaskFamiliarity() {
    }

    public double TaskFamiliarity(double[] var1) {
        double[] var2 = new double[]{4395.15617934498D, -26293.30025130012D, 24757.94323660191D, 4.254936656547593E12D, -4.037760947009798E13D, -7907.647562089014D};
        int[] var3 = new int[]{25, 33, 17, 8, 27};
        double[] var4 = new double[28672];

        int var5;
        for(var5 = 0; var5 < 28672; ++var5) {
            var4[var5] = var1[var5];
        }

        TF_TD_Libraries var35 = new TF_TD_Libraries();
        var35.getClass();
        var1 = (new TF_TD_PREPROCESSING(var35)).TF_TD_preprocessing(var4, 512);
        var35.getClass();
        FeatureExtrationReturn var30;
        double var10 = (var30 = (new TF_TD_FEATUREEXTRACTION(var35)).TF_TD_featureextraction(var1, 512, 2, 1)).get_hjorth_activity();
        double var12 = var30.get_hjorth_mobility();
        double var14 = var30.get_hjorth_complexity();
        var4 = var30.get_bp_row_mean();
        var30.get_rbp_row_mean();
        double[] var34 = var30.get_bp_activity();
        double[] var6 = var30.get_bp_mobility();
        var1 = var30.get_bp_complexity();
        double[] var7 = new double[var4.length + 1 + 1 + 1 + var34.length + var6.length + var1.length];
        int var8 = 0;

        int var9;
        for(var9 = 0; var9 < var4.length; ++var9) {
            var7[var8] = var4[var9];
            ++var8;
        }

        var7[var8] = var10;
        ++var8;
        var7[var8] = var12;
        ++var8;
        var7[var8] = var14;
        ++var8;

        for(var9 = 0; var9 < var34.length; ++var9) {
            var7[var8] = var34[var9];
            ++var8;
        }

        for(var9 = 0; var9 < var6.length; ++var9) {
            var7[var8] = var6[var9];
            ++var8;
        }

        for(var9 = 0; var9 < var1.length; ++var9) {
            var7[var8] = var1[var9];
            ++var8;
        }

        var9 = var3[0] - 1;
        int var31 = var3[1] - 1;
        int var33 = var3[2] - 1;
        var5 = var3[3] - 1;
        int var32 = var3[4] - 1;
        return var2[0] + var2[1] * var7[var9] + var2[2] * var7[var31] + var2[3] * var7[var33] + var2[4] * var7[var5] + var2[5] * var7[var32];
    }
}
